package cn.wolfcode.wolf2w.controller;

import cn.wolfcode.wolf2w.annotation.UserInfoParam;
import cn.wolfcode.wolf2w.domain.UserInfo;
import cn.wolfcode.wolf2w.redis.service.IPersonalService;
import cn.wolfcode.wolf2w.util.JsonResult;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.Map;

@RestController
@RequestMapping("/personals")
public class PersonalController {
	@Autowired
	private IPersonalService personalService;

	@GetMapping("/viewnumVo")
	public Object accessnumVo(String ownerId, @UserInfoParam UserInfo userInfo){
		Map map = personalService.getViewnumVo(ownerId,userInfo.getId());
		return JsonResult.success(map);
	}
}
